package com.czk.controller;

import com.czk.mapper.UserMapper;
import com.czk.pojo.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

/**
 * 垂直分库，专库专表的测试
 * @Author:ChenZhangKun
 * @Date: 2021/6/20 15:33
 */
//@RestController
@RequestMapping("/user")
public class UserController {
    @Autowired
    private UserMapper userMapper;
    @GetMapping("/insert")
    public User insertUser() {
        User user = new User();
        user.setUsername("czk");
        user.setUstatus("帅");
        userMapper.insert(user);
        return user;
    }
}
